home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 4592 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.6 KB  |  50 lines

  1. Newsgroups: comp.sys.amiga.programmer
  2. Path: chang.unx.sas.com!walker
  3. From: walker@chang.unx.sas.com (Doug Walker)
  4. Subject: Re: SasC linker Error:
  5. Sender: news@unx.sas.com (Noter of Newsworthy Events)
  6. Message-ID: <DnLnMG.7C9@unx.sas.com>
  7. Date: Fri, 1 Mar 1996 17:37:28 GMT
  8. X-Nntp-Posting-Host: chang.unx.sas.com
  9. References: <dkauppDnEzzs.FsD@netcom.com>
  10. Organization: SAS Institute Inc.
  11.  
  12. In article <dkauppDnEzzs.FsD@netcom.com>, Blitter <dkaupp@netcom.com> wrote:
  13. > Can someone tell me what may be causing these errors? MOBtrigger is a 
  14. >BOOL and as far a I know, its just changed using TRUE and FALSE.
  15. >
  16. > If someone can point me in the right direction I would appriciate it :).
  17.  
  18. You have a data definition in a header file.  You should have a DECLARATION
  19. in the header file, and put the definition in a C file somewhere.
  20.  
  21. Look for a statement like
  22.  
  23.    BOOL MOBtrigger;
  24.  
  25. in the header file and replace it with
  26.  
  27.    extern BOOL MOBtrigger;
  28.  
  29. then edit any one of your .c files that includes the header and put
  30.  
  31.    BOOL MOBtrigger;
  32.    
  33. in it.  Note that MOBtrigger will be initialized to zero by default
  34. (since it is an extern), but if you have an explicit intializer you
  35. need to move the initializer into the .c file.  You should not have
  36. an initializer in the .h file.
  37.  
  38. Example with initializer:
  39.  
  40.    BOOL MOBtrigger = TRUE;  /* Not in header file! */
  41.  
  42. -- 
  43.   *****                    / walker@unx.sas.com
  44.  *|_o_o|\\     Doug Walker<  BIX, Portal: djwalker
  45.  *|. o.| ||                \ AOL: weissblau
  46.   | o  |//     
  47.   ====== 
  48. Any opinions expressed are mine, not those of SAS Institute, Inc.
  49.  
  50.